package com.example.guestbook.pojo;

import java.util.ArrayList;
import java.util.Date;
import java.util.List;

public class BooklistExample {
    protected String orderByClause;

    protected boolean distinct;

    protected List<Criteria> oredCriteria;

    public BooklistExample() {
        oredCriteria = new ArrayList<>();
    }

    public void setOrderByClause(String orderByClause) {
        this.orderByClause = orderByClause;
    }

    public String getOrderByClause() {
        return orderByClause;
    }

    public void setDistinct(boolean distinct) {
        this.distinct = distinct;
    }

    public boolean isDistinct() {
        return distinct;
    }

    public List<Criteria> getOredCriteria() {
        return oredCriteria;
    }

    public void or(Criteria criteria) {
        oredCriteria.add(criteria);
    }

    public Criteria or() {
        Criteria criteria = createCriteriaInternal();
        oredCriteria.add(criteria);
        return criteria;
    }

    public Criteria createCriteria() {
        Criteria criteria = createCriteriaInternal();
        if (oredCriteria.size() == 0) {
            oredCriteria.add(criteria);
        }
        return criteria;
    }

    protected Criteria createCriteriaInternal() {
        Criteria criteria = new Criteria();
        return criteria;
    }

    public void clear() {
        oredCriteria.clear();
        orderByClause = null;
        distinct = false;
    }

    protected abstract static class GeneratedCriteria {
        protected List<Criterion> criteria;

        protected GeneratedCriteria() {
            super();
            criteria = new ArrayList<>();
        }

        public boolean isValid() {
            return criteria.size() > 0;
        }

        public List<Criterion> getAllCriteria() {
            return criteria;
        }

        public List<Criterion> getCriteria() {
            return criteria;
        }

        protected void addCriterion(String condition) {
            if (condition == null) {
                throw new RuntimeException("Value for condition cannot be null");
            }
            criteria.add(new Criterion(condition));
        }

        protected void addCriterion(String condition, Object value, String property) {
            if (value == null) {
                throw new RuntimeException("Value for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value));
        }

        protected void addCriterion(String condition, Object value1, Object value2, String property) {
            if (value1 == null || value2 == null) {
                throw new RuntimeException("Between values for " + property + " cannot be null");
            }
            criteria.add(new Criterion(condition, value1, value2));
        }

        public Criteria andBookidIsNull() {
            addCriterion("BookID is null");
            return (Criteria) this;
        }

        public Criteria andBookidIsNotNull() {
            addCriterion("BookID is not null");
            return (Criteria) this;
        }

        public Criteria andBookidEqualTo(Integer value) {
            addCriterion("BookID =", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidNotEqualTo(Integer value) {
            addCriterion("BookID <>", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidGreaterThan(Integer value) {
            addCriterion("BookID >", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidGreaterThanOrEqualTo(Integer value) {
            addCriterion("BookID >=", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidLessThan(Integer value) {
            addCriterion("BookID <", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidLessThanOrEqualTo(Integer value) {
            addCriterion("BookID <=", value, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidIn(List<Integer> values) {
            addCriterion("BookID in", values, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidNotIn(List<Integer> values) {
            addCriterion("BookID not in", values, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidBetween(Integer value1, Integer value2) {
            addCriterion("BookID between", value1, value2, "bookid");
            return (Criteria) this;
        }

        public Criteria andBookidNotBetween(Integer value1, Integer value2) {
            addCriterion("BookID not between", value1, value2, "bookid");
            return (Criteria) this;
        }

        public Criteria andUsernameIsNull() {
            addCriterion("UserName is null");
            return (Criteria) this;
        }

        public Criteria andUsernameIsNotNull() {
            addCriterion("UserName is not null");
            return (Criteria) this;
        }

        public Criteria andUsernameEqualTo(String value) {
            addCriterion("UserName =", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameNotEqualTo(String value) {
            addCriterion("UserName <>", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameGreaterThan(String value) {
            addCriterion("UserName >", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameGreaterThanOrEqualTo(String value) {
            addCriterion("UserName >=", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameLessThan(String value) {
            addCriterion("UserName <", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameLessThanOrEqualTo(String value) {
            addCriterion("UserName <=", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameLike(String value) {
            addCriterion("UserName like", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameNotLike(String value) {
            addCriterion("UserName not like", value, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameIn(List<String> values) {
            addCriterion("UserName in", values, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameNotIn(List<String> values) {
            addCriterion("UserName not in", values, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameBetween(String value1, String value2) {
            addCriterion("UserName between", value1, value2, "username");
            return (Criteria) this;
        }

        public Criteria andUsernameNotBetween(String value1, String value2) {
            addCriterion("UserName not between", value1, value2, "username");
            return (Criteria) this;
        }

        public Criteria andBooktitleIsNull() {
            addCriterion("BookTitle is null");
            return (Criteria) this;
        }

        public Criteria andBooktitleIsNotNull() {
            addCriterion("BookTitle is not null");
            return (Criteria) this;
        }

        public Criteria andBooktitleEqualTo(String value) {
            addCriterion("BookTitle =", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleNotEqualTo(String value) {
            addCriterion("BookTitle <>", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleGreaterThan(String value) {
            addCriterion("BookTitle >", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleGreaterThanOrEqualTo(String value) {
            addCriterion("BookTitle >=", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleLessThan(String value) {
            addCriterion("BookTitle <", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleLessThanOrEqualTo(String value) {
            addCriterion("BookTitle <=", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleLike(String value) {
            addCriterion("BookTitle like", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleNotLike(String value) {
            addCriterion("BookTitle not like", value, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleIn(List<String> values) {
            addCriterion("BookTitle in", values, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleNotIn(List<String> values) {
            addCriterion("BookTitle not in", values, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleBetween(String value1, String value2) {
            addCriterion("BookTitle between", value1, value2, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBooktitleNotBetween(String value1, String value2) {
            addCriterion("BookTitle not between", value1, value2, "booktitle");
            return (Criteria) this;
        }

        public Criteria andBookfaceIsNull() {
            addCriterion("BookFace is null");
            return (Criteria) this;
        }

        public Criteria andBookfaceIsNotNull() {
            addCriterion("BookFace is not null");
            return (Criteria) this;
        }

        public Criteria andBookfaceEqualTo(String value) {
            addCriterion("BookFace =", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceNotEqualTo(String value) {
            addCriterion("BookFace <>", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceGreaterThan(String value) {
            addCriterion("BookFace >", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceGreaterThanOrEqualTo(String value) {
            addCriterion("BookFace >=", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceLessThan(String value) {
            addCriterion("BookFace <", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceLessThanOrEqualTo(String value) {
            addCriterion("BookFace <=", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceLike(String value) {
            addCriterion("BookFace like", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceNotLike(String value) {
            addCriterion("BookFace not like", value, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceIn(List<String> values) {
            addCriterion("BookFace in", values, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceNotIn(List<String> values) {
            addCriterion("BookFace not in", values, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceBetween(String value1, String value2) {
            addCriterion("BookFace between", value1, value2, "bookface");
            return (Criteria) this;
        }

        public Criteria andBookfaceNotBetween(String value1, String value2) {
            addCriterion("BookFace not between", value1, value2, "bookface");
            return (Criteria) this;
        }

        public Criteria andBooktimeIsNull() {
            addCriterion("BookTime is null");
            return (Criteria) this;
        }

        public Criteria andBooktimeIsNotNull() {
            addCriterion("BookTime is not null");
            return (Criteria) this;
        }

        public Criteria andBooktimeEqualTo(Date value) {
            addCriterion("BookTime =", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeNotEqualTo(Date value) {
            addCriterion("BookTime <>", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeGreaterThan(Date value) {
            addCriterion("BookTime >", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeGreaterThanOrEqualTo(Date value) {
            addCriterion("BookTime >=", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeLessThan(Date value) {
            addCriterion("BookTime <", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeLessThanOrEqualTo(Date value) {
            addCriterion("BookTime <=", value, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeIn(List<Date> values) {
            addCriterion("BookTime in", values, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeNotIn(List<Date> values) {
            addCriterion("BookTime not in", values, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeBetween(Date value1, Date value2) {
            addCriterion("BookTime between", value1, value2, "booktime");
            return (Criteria) this;
        }

        public Criteria andBooktimeNotBetween(Date value1, Date value2) {
            addCriterion("BookTime not between", value1, value2, "booktime");
            return (Criteria) this;
        }

        public Criteria andBookipIsNull() {
            addCriterion("BookIP is null");
            return (Criteria) this;
        }

        public Criteria andBookipIsNotNull() {
            addCriterion("BookIP is not null");
            return (Criteria) this;
        }

        public Criteria andBookipEqualTo(String value) {
            addCriterion("BookIP =", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipNotEqualTo(String value) {
            addCriterion("BookIP <>", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipGreaterThan(String value) {
            addCriterion("BookIP >", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipGreaterThanOrEqualTo(String value) {
            addCriterion("BookIP >=", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipLessThan(String value) {
            addCriterion("BookIP <", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipLessThanOrEqualTo(String value) {
            addCriterion("BookIP <=", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipLike(String value) {
            addCriterion("BookIP like", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipNotLike(String value) {
            addCriterion("BookIP not like", value, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipIn(List<String> values) {
            addCriterion("BookIP in", values, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipNotIn(List<String> values) {
            addCriterion("BookIP not in", values, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipBetween(String value1, String value2) {
            addCriterion("BookIP between", value1, value2, "bookip");
            return (Criteria) this;
        }

        public Criteria andBookipNotBetween(String value1, String value2) {
            addCriterion("BookIP not between", value1, value2, "bookip");
            return (Criteria) this;
        }
    }

    public static class Criteria extends GeneratedCriteria {
        protected Criteria() {
            super();
        }
    }

    public static class Criterion {
        private String condition;

        private Object value;

        private Object secondValue;

        private boolean noValue;

        private boolean singleValue;

        private boolean betweenValue;

        private boolean listValue;

        private String typeHandler;

        public String getCondition() {
            return condition;
        }

        public Object getValue() {
            return value;
        }

        public Object getSecondValue() {
            return secondValue;
        }

        public boolean isNoValue() {
            return noValue;
        }

        public boolean isSingleValue() {
            return singleValue;
        }

        public boolean isBetweenValue() {
            return betweenValue;
        }

        public boolean isListValue() {
            return listValue;
        }

        public String getTypeHandler() {
            return typeHandler;
        }

        protected Criterion(String condition) {
            super();
            this.condition = condition;
            this.typeHandler = null;
            this.noValue = true;
        }

        protected Criterion(String condition, Object value, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.typeHandler = typeHandler;
            if (value instanceof List<?>) {
                this.listValue = true;
            } else {
                this.singleValue = true;
            }
        }

        protected Criterion(String condition, Object value) {
            this(condition, value, null);
        }

        protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
            super();
            this.condition = condition;
            this.value = value;
            this.secondValue = secondValue;
            this.typeHandler = typeHandler;
            this.betweenValue = true;
        }

        protected Criterion(String condition, Object value, Object secondValue) {
            this(condition, value, secondValue, null);
        }
    }
}